package com.zjw.starter.fegin.factory;

import com.zjw.starter.fegin.RemoteRegisterService;
import com.zjw.starter.fegin.fallback.RemoteRegisterFallback;
import org.springframework.cloud.openfeign.FallbackFactory;
import org.springframework.stereotype.Component;

@Component
public class RemoteRegisterServiceFactory implements FallbackFactory<RemoteRegisterService> {

    @Override
    public RemoteRegisterService create(Throwable cause) {
        return new RemoteRegisterFallback();
    }
}
